public class Text {
    public static void main(String[] args) {

    }
    //链表中的回文结构
    /*public boolean chkPalindrome(ListNode A) {

        if(A == null){
            return false;
        }
        if(A.next == null){
            return true;
        }
        ListNode fast = A;
        ListNode slow = A;
        while(fast != null && fast.next != null){
            fast = fast.next.next;
            slow = slow.next;
        }
        ListNode cur = slow.next;
        while(cur != null){
            ListNode curnext = cur.next;
            cur.next=slow;
            slow = cur;
            cur = curnext;
        }
        while(A != slow){
            if(A.val == slow.val){
                A=A.next;
                slow=slow.next;
            }else{
                return false;
            }
            if(A.next.val == slow.val){
                return true;
            }
        }

        return true;
    }*/
    //链表中倒数k个节点
    /*public static ListNode FindKthToTail(ListNode head,int k) {
        if(head == null){
            return null;
        }
        ListNode fast = head;
        ListNode slow = head;
        while(k != 0){
            k--;
            if(fast == null){
                return null;
            }
            fast= fast.next;
        }
        while(fast != null){
            fast=fast.next;
            slow=slow.next;
        }
        return slow;
    }*/
}
